/*
 * TableItemTransferBean.java
 *
 * Copyright 2007, 2008 Tiberiumlabs
 *
 * This file is part of Tiberiumlabs Lailaps.
 *
 * Tiberiumlabs Lailaps is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 3 of the License, or
 * (at your option) any later version.
 *
 * Tiberiumlabs Lailaps is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

package org.tiberiumlabs.lailaps.gui.transfer;

import java.awt.datatransfer.DataFlavor;

/**
 *
 * @author <a href="mailto:beast.tiberiumlabs@gmail.com">Beast</a>
 */
public class TableSelectionBean {

    public static final DataFlavor tableSelectionFlavor = 
            new DataFlavor(TableSelectionBean.class, "TableSelectionBean");
    
    private String[] URIs;
    private int[] rows;

    public TableSelectionBean(String[] URIs, int[] rows) {
        this.URIs = URIs;
        this.rows = rows;
    }    
    
    public String[] getURIs() {
        return URIs;
    }

    public void setURIs(String[] URIs) {
        this.URIs = URIs;
    }

    public int[] getRows() {
        return rows;
    }

    public void setRows(int[] rows) {
        this.rows = rows;
    }

    @Override
    public String toString() {
        StringBuilder output = new StringBuilder();
        for (int i=0; i < URIs.length; i++) {
            output.append(URIs[i]);
            if (i+1 < URIs.length) {
                output.append('\n');
            }
        }
        return output.toString();
    }
        
}
